﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
using BUSINESS_OBJECT;
namespace CRM
{
    public partial class _Default : System.Web.UI.Page
    {
      Custcls cust = new Custcls();
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                DataTable dt = cust.GetRecords(-99, "", "", "", "", -99, "",Convert.ToDateTime( "1/1/1800"), -99, "", "", "","","","", false, " and ");
           }
        }

        protected void Button1_Click(object sender, EventArgs e)
        {
            cust.CID = -99;
            cust.CUSTOMER_NAME=txtCustName.Text;
            cust.COMPANY_NAME = txtcmpname.Text;
            cust.COMPANY_ADDRESS = txtcmpadd.Text;
            cust.SERVICE_TYPE = txtservictyp.Text;
            cust.PHONE_NO = Convert.ToInt64(txtcontectno.Text);
            cust.CC_TYPE = txtcctyp.Text;
            cust.CC_EXR_DATE = Convert.ToDateTime(txtccexp.Text);
            cust.CC_NUMBER = Convert.ToInt64(txtccnum.Text);
            cust.CC_PINCODE = Convert.ToInt64(txtccpin.Text);
            cust.EMAIL_ID = txteid.Text;
            cust.CUSER_NAME=txtusername.Text;
            cust.CPASSWORD = txtpaswd.Text;
            cust.SECURITY_QUESTION = DropDownList1.SelectedItem.ToString();
            cust.ANSWER = TextBox1.Text;
            cust.ISDELETED = false;
            cust.SaveRecords();
            Response.Redirect("~/Customer/home.aspx");

   

        }

       
    }
}
